﻿using System;

namespace YJKCopyModel.InteractiveOperation
{
	public class DwgEntitiesSelectionCommon
	{
		public static string GetResultInfo(DwgEntitiesSelectionResult dwgEntitiesSelectionResult, out bool isCancel)
		{
			isCancel = false;
			bool flag = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eUnitError;
			string result;
			if (flag)
			{
				result = "链接图纸的导入单位必须是毫米！";
			}
			else
			{
				bool flag2 = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eDataError;
				if (flag2)
				{
					result = "所选图元数据不正确！";
				}
				else
				{
					bool flag3 = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eDwgPathError;
					if (flag3)
					{
						result = "链接图纸的路径不正确！";
					}
					else
					{
						bool flag4 = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eNotGetBlock;
						if (flag4)
						{
							result = "未能获取到块参照！";
						}
						else
						{
							bool flag5 = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eNotLinkDwg;
							if (flag5)
							{
								result = "仅支持链接的dwg图纸！";
							}
							else
							{
								bool flag6 = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eNotAnalysisDwg;
								if (flag6)
								{
									result = "未能解析dwg图纸，请使用CAD修复图纸、降低图纸版本。";
								}
								else
								{
									bool flag7 = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eOtherError;
									if (flag7)
									{
										result = "执行命令发生错误！命令必须结束！";
									}
									else
									{
										bool flag8 = dwgEntitiesSelectionResult == DwgEntitiesSelectionResult.eCancel;
										if (flag8)
										{
											isCancel = true;
											result = "用户取消！";
										}
										else
										{
											result = "执行命令发生错误！命令必须结束！";
										}
									}
								}
							}
						}
					}
				}
			}
			return result;
		}
	}
}
